import request from '@/utils/request';
import type { UserParam } from '@/types/admin/users';

export async function fetchUsers(params: UserParam) {
  try {
    const res = await request.post("/admin/user/page", { params });
    console.log('用户请求成功:', res);
    return res;
  } catch (error) {
    console.error('用户请求失败:', error);
    throw error;
  }
}
